package net.web.entity;

import java.util.Objects;

public class BlogView {


    private Integer id;
    private String title;
    private String content;
    private String excerpt;
    private String coverimage;
    private Integer classid;
    private Integer authorid;
    //private String status;
    private Boolean isfeatured;
    private Boolean iscommentable;
    private Integer viewcount;
    private Integer likecount;
    private String metatitle;
    private String metadescription;
    private String metakeywords;
    private String publishedat;
    private String createdat;
    private String updatedat;
    private Boolean flag;

    public BlogView() {
    }

    public BlogView(String title, String content, String excerpt, String coverimage, Integer classid, Integer authorid, Boolean isfeatured, Boolean iscommentable, Integer viewcount, Integer likecount, String metatitle, String metadescription, String metakeywords, String publishedat, String createdat, String updatedat,Boolean flag) {
        this.title = title;
        this.content = content;
        this.excerpt = excerpt;
        this.coverimage = coverimage;
        this.classid = classid;
        this.authorid = authorid;
        this.isfeatured = isfeatured;
        this.iscommentable = iscommentable;
        this.viewcount = viewcount;
        this.likecount = likecount;
        this.metatitle = metatitle;
        this.metadescription = metadescription;
        this.metakeywords = metakeywords;
        this.publishedat = publishedat;
        this.createdat = createdat;
        this.updatedat = updatedat;
        this.flag = flag;
    }

    public BlogView(Integer id,String title, String content, String excerpt, String coverimage, Integer classid, Integer authorid, Boolean isfeatured, Boolean iscommentable, Integer viewcount, Integer likecount, String metatitle, String metadescription, String metakeywords, String publishedat, String createdat, String updatedat,Boolean flag) {
        this.id = id;
        this.title = title;
        this.content = content;
        this.excerpt = excerpt;
        this.coverimage = coverimage;
        this.classid = classid;
        this.authorid = authorid;
        this.isfeatured = isfeatured;
        this.iscommentable = iscommentable;
        this.viewcount = viewcount;
        this.likecount = likecount;
        this.metatitle = metatitle;
        this.metadescription = metadescription;
        this.metakeywords = metakeywords;
        this.publishedat = publishedat;
        this.createdat = createdat;
        this.updatedat = updatedat;
        this.flag = flag;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getExcerpt() {
        return excerpt;
    }

    public void setExcerpt(String excerpt) {
        this.excerpt = excerpt;
    }

    public String getCover_image() {
        return coverimage;
    }

    public void setCover_image(String coverimage) {
        this.coverimage = coverimage;
    }

    public Integer getClass_id() {
        return classid;
    }

    public void setCategory_id(Integer classid) {
        this.classid = classid;
    }

    public Integer getAuthor_id() {
        return authorid;
    }

    public void setAuthor_id(Integer authorid) {
        this.authorid = authorid;
    }


    public Boolean getIs_featured() {
        return isfeatured;
    }

    public void setIs_featured(Boolean isfeatured) {
        this.isfeatured = isfeatured;
    }

    public Boolean getIs_commentable() {
        return iscommentable;
    }

    public void setIs_commentable(Boolean iscommentable) {
        this.iscommentable = iscommentable;
    }

    public Integer getView_count() {
        return viewcount;
    }

    public void setView_count(Integer viewcount) {
        this.viewcount = viewcount;
    }

    public Integer getLike_count() {
        return likecount;
    }

    public void setLike_count(Integer likecount) {
        this.likecount = likecount;
    }

    public String getMeta_title() {
        return metatitle;
    }

    public void setMeta_title(String metatitle) {
        this.metatitle = metatitle;
    }

    public String getMeta_description() {
        return metadescription;
    }

    public void setMeta_description(String metadescription) {
        this.metadescription = metadescription;
    }

    public String getMeta_keywords() {
        return metakeywords;
    }

    public void setMeta_keywords(String metakeywords) {
        this.metakeywords = metakeywords;
    }

    public String getPublished_at() {
        return publishedat;
    }

    public void setPublished_at(String publishedat) {
        this.publishedat = publishedat;
    }

    public String getCreated_at() {
        return createdat;
    }

    public void setCreated_at(String createdat) {
        this.createdat = createdat;
    }

    public String getUpdated_at() {
        return updatedat;
    }

    public void setUpdated_at(String updatedat) {
        this.updatedat = updatedat;
    }

    public Boolean getFlag() {
        return flag;
    }

    public void setFlag(Boolean flag) {this.flag = flag;}

    @Override
    public boolean equals(Object o) {
        if (o == null || getClass() != o.getClass()) return false;
        BlogView blogView = (BlogView) o;
        return Objects.equals(id, blogView.id) && Objects.equals(title, blogView.title) && Objects.equals(content, blogView.content) && Objects.equals(excerpt, blogView.excerpt) && Objects.equals(coverimage, blogView.coverimage) && Objects.equals(classid, blogView.classid) && Objects.equals(authorid, blogView.authorid) && Objects.equals(isfeatured, blogView.isfeatured) && Objects.equals(iscommentable, blogView.iscommentable) && Objects.equals(viewcount, blogView.viewcount) && Objects.equals(likecount, blogView.likecount) && Objects.equals(metatitle, blogView.metatitle) && Objects.equals(metadescription, blogView.metadescription) && Objects.equals(metakeywords, blogView.metakeywords) && Objects.equals(publishedat, blogView.publishedat) && Objects.equals(createdat, blogView.createdat) && Objects.equals(updatedat, blogView.updatedat)&& Objects.equals(flag, blogView.flag);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, title, content, excerpt, coverimage, classid, authorid, isfeatured, iscommentable, viewcount, likecount, metatitle, metadescription, metakeywords, publishedat, createdat, updatedat, flag);
    }

    @Override
    public String toString() {
        return "Blog{" +
                "id=" + id +
                ", title='" + title + '\'' +
                ", content='" + content + '\'' +
                ", excerpt='" + excerpt + '\'' +
                ", coverimage='" + coverimage + '\'' +
                ", classid=" + classid +
                ", authorid=" + authorid +
                ", isfeatured=" + isfeatured +
                ", iscommentable=" + iscommentable +
                ", viewcount=" + viewcount +
                ", likecount=" + likecount +
                ", metatitle='" + metatitle + '\'' +
                ", metadescription='" + metadescription + '\'' +
                ", metakeywords='" + metakeywords + '\'' +
                ", publishedat='" + publishedat + '\'' +
                ", createdat='" + createdat + '\'' +
                ", updatedat='" + updatedat + '\'' +
                ", flag='" + flag + '\'' +
                '}';
    }
}
